home *** CD-ROM | disk | FTP | other *** search
/ Internet Info 1994 March / Internet Info CD-ROM (Walnut Creek) (March 1994).iso / networking / ip / ka9q / aztecnos.arc / HAPNVEC.ASM < prev    next >
Encoding:
Assembly Source File  |  1988-09-25  |  780 b   |  46 lines

  1.     include lmacros.h
  2.     assume    ds:dataseg
  3.     extrn    _Dorg_:byte
  4.     extrn    Sssave:word,Spsave:word,Intstk_:byte
  5.  
  6.     ifdef    FARPROC
  7.     extrn    doret:far,haint_:far
  8.     else
  9.     extrn    doret:near,haint_:near
  10.     endif
  11.  
  12. dbase    dw    seg _Dorg_    ; save loc for ds (must be in code segment)
  13.  
  14. ; ha0vec - HAPN card #0 interrupt handler
  15.     public    ha0vec_
  16.  
  17. ha0vec_    proc    far
  18.     push    ds        ; save on user stack
  19.     mov    ds,cs:dbase    ; establish interrupt data segment
  20.  
  21.     mov    Sssave,ss    ; stash user stack context
  22.     mov    Spsave,sp
  23.  
  24.     mov    ss,cs:dbase    
  25.     lea    sp,Intstk_+512
  26.  
  27.     push    ax        ; save user regs on interrupt stack
  28.     push    bx
  29.     push    cx
  30.     push    dx
  31.     push    bp
  32.     push    si
  33.     push    di
  34.     push    es
  35.     push    ds
  36.     pop    es
  37.  
  38.     mov    ax,0        ; arg for service routine
  39.     push    ax
  40.     call    haint_
  41.     pop    ax
  42.     jmp    doret
  43. ha0vec_    endp
  44.  
  45.     end
  46.